Automated Presentation of directory src/exampleCode/stereo/stereotest/

HUB | Up | Download | Pheedbak | Tree | Topic | A-Z | Search | Hot | New


README file from "stereotest" directory

---------------------------------------------------------------------------

	Stereo Test Demo

	Todd Kulick
	96/06/11

---------------------------------------------------------------------------


This directory contains a program that demonstrates the use of the
stereo-in-a-window feature.  This program is intended to demonstrate
stereo-in-a-window with a model that can be interactively manipulated
and moved.  Many other options are provided as well.  The source code
is also included to provide a simple example of how to write code
using the stereo-in-a-window feature.  To run this program simply
issue the following command:

$ ./stereotest

More details on setting your system up to provide stereo mode visuals
is included below.


---------------------------------------------------------------------------

	Functions

---------------------------------------------------------------------------

The rendering output in the stereo test window can be changed via key
and mouse input.

The left mouse button is used to rotate the model.  The model will
autospin if released quickly.  The middle mouse button can be used to
zoom the model by holding the mouse button down and dragging
vertically.

	Button	Motion		Function

	left	vert & horiz	Rotate and autospin the model
	middle	vert		Zoom the model

A number of keys provide a host of functions.  Some keys simply toggle
or cycle through a collection of options.  All keys are listed in
the table below.

	Key	Function

	-/_	Decrease level (resolution) of model
	+/=	Increase level (resolution) of model

	Home	Increase model offset
	End	Decrease model offset

	PageUp	Increase model size
	PageDwn	Decrease model size

	p/F1	Toggle orthographic & perspective projection
	l/F2	Toggle lighting & flat shading
	w/F3	Toggle filled & wireframe
	c/F4	Toggle color & black and white display
	s/F5	Toggle monocular & stereo
	f/F6	Toggle double & single buffering
	m/F7	Next model (spheres -> arrows -> cubes)
	M/F8	Previous model (spheres -> cubes -> arrows)
	e/F9	Toggle display of the eye view window
	z/F10	Toggle Zirl! mode (moving model)
	Z/F11	Reset model to initial state
	r/F12	Reset all parameters

	1	Toggle use of light 1 (white left)
	2	Toggle use of light 2 (white right)
	3	Toggle use of light 3 (yellow above)
	4	Toggle use of light 4 (red below left)
	5	Toggle use of light 5 (green above)
	6	Toggle use of light 6 (blue right)

	Right	Increase stereo separation of eyes
	Left	Decrease stereo separation of eyes

	Up	Increase stereo focal distance of eyes
	Down	Decrease stereo focal distance of eyes

	Q/ESC	Quit


---------------------------------------------------------------------------

	Stereo Coding

---------------------------------------------------------------------------

This program is intended to be a stereo-in-a-window coding example.
All of the rendering code for this program is in the file
'iRenderWindow.C'.  It demonstrates how to maintain and install stereo
separation and stereo focal distance parameters while rendering in
monocular or stereoptic modes.


---------------------------------------------------------------------------

	Stereo Mode Details

---------------------------------------------------------------------------

If the present X server mode does not provide any visuals capable of
stereo the program will notify you with the warning message shown
below.  The program can still be run, but stereo will not work.

$ ./stereotest 
Unable to get an acceptable stereo visual!
Running in mono mode!

Remember that certain machines will not provide stereo capable visuals
unless the X server is running a certain VOF (video output format).
The VOF may be changed using the setmon(1G) command.  The details are
system specific, refer to the man page.

Also, Irix 6.2 contains a program, glxinfo(1G), useful in determining
the available visuals.  The output contains a column specifying
whether or not the given visual supports stereo ('stro').

On my High Impact, for example, I might try the following:

$ glxinfo

[... some output cut for compactness ..]

   visual  x  bf lv rg d st  r  g  b a  ax dp st accum buffs  ms 
 id dep cl sp sz l  ci b ro sz sz sz sz bf th cl  r  g  b  a ns b
-----------------------------------------------------------------
0x20  8 pc  .  8  . c  .  .  .  .  .  .  . 24  8  .  .  .  .  . .
0x21  8 pc  .  8  . c  .  .  .  .  .  .  .  .  .  .  .  .  .  . .
0x23  8 pc  y  8  1 c  .  .  .  .  .  .  .  .  .  .  .  .  .  . .
0x24  8 pc  .  8  1 c  .  .  .  .  .  .  .  .  .  .  .  .  .  . .
0x25 12 pc  . 12  . b  .  . 12  .  .  .  . 24  8  .  .  .  .  . .
0x26 12 pc  . 12  . b  .  . 12  .  .  .  .  .  .  .  .  .  .  . .
0x27 12 pc  . 12  . b  y  . 12  .  .  .  . 24  8  .  .  .  .  . .
0x28 12 pc  . 12  . b  y  . 12  .  .  .  .  .  .  .  .  .  .  . .
0x29 12 tc  . 12  . r  y  .  4  4  4  4  . 24  8 16 16 16 16  . .
0x2a 12 tc  . 12  . r  y  .  4  4  4  4  .  .  . 16 16 16 16  . .
0x2b 15 tc  . 15  . r  y  .  5  5  5  1  . 24  8 16 16 16 16  . .
0x2c 15 tc  . 15  . r  y  .  5  5  5  1  .  .  . 16 16 16 16  . .
0x2d 24 tc  . 24  . r  .  .  8  8  8  8  . 24  8 16 16 16 16  . .
0x2e 24 tc  . 24  . r  .  .  8  8  8  8  .  .  . 16 16 16 16  . .
0x2f 24 tc  . 24  . r  .  . 12 12 12  .  . 24  8 16 16 16 16  . .
0x30 24 tc  . 24  . r  .  . 12 12 12  .  .  .  . 16 16 16 16  . .

                          ^
                          |
   Stereo visual flag ----+

Seeing that none of these visuals support stereo, I would switch to a
smaller running resolution (VOF) that provides stereo visuals.  To do
this I would issue the command:

$ setmon -x 1280x1024_96s

Then log out and log back in.

Files of interest from "src/exampleCode/stereo/stereotest" directory

Source

Documentation

Reference


Select any combo of files you'd like to send yourself a compressed tar image of. Executables/scripts are indicated with a trailing `*' character. (Depending upon the browser, it may be necessary to hold down the Ctrl key to select/deselect disjoint items.) a compressed tar image of the above-selected items.
OR, ...
a compressed tar image of the entire stereotest directory.

Copyright © 1996, Silicon Graphics, Inc.